package engine.game;
/**
 * game engine class
 * @author larnima
 * basically take the new input form all the team's players and 
 * calculate the game answer (i.e. the new turn)
 * NOTE : all the game engine is base on the Design Pattern Observer 
 * and its notify/handling behavior 
 */
public class VolleyGame {
	/* *********************************************************
	 * Attributes
	 * ********************************************************* */
	private Board _hinbBoard;
	private GameState _currentState;
	//TODO private score ...
	
	/* *********************************************************
	 * Constructor(s)
	 * ********************************************************* */
	public VolleyGame(){
		//TODO ///
	}
	
	/* *********************************************************
	 * Instance Methods
	 * ********************************************************* */
	public void startGame(){
		while(this._currentState != GameState.GAME_OVER){
			//Fst ask for the new input from the players :
			_hinbBoard.refreshPlayersAction();
			// then ask the board to calculate the new position of moving 
			// objects
			_hinbBoard.newTurn();
			//collision between physical objects events are launched and 
			//handle here
			
			//don't forget to set the new gameState
		}
		System.out.println("like an old president said : " +
				"\"the game is over\"");
	}
	
	/* *********************************************************
	 * Tests
	 * But Prefer writing a TestFile in the Test Package
	 * ********************************************************* */
	public static void main(String[] args) {
		
	}
}
